Descriptive Statistics: Two Variables
Tao Lin
Office Hours: Fri 1:30 - 3:30 PM Smith 35
Section Slides URL: soxv/CSSS-321-Labs
Agenda
Survey Sampling
Correlation
Quantile-Quantile Plot
Deciphering Problem Set 2
Source: Groves et al. 2009
Agenda
Survey Sampling
Correlation
Quantile-Quantile Plot
Deciphering Problem Set 2
\begin{aligned} \text{Corr}(x, y) =& \frac{\text{Cov}(x, y)}{\sigma_x \sigma_y} \\ =& \frac{\frac{1}{n-1}\sum_{i=1}^n [(x_i - \bar{x}) (y_i - \bar{y})]}{\sigma_x \sigma_y} \\ =& \frac{1}{n-1}\sum_{i=1}^n [\text{z-score}(x) \times \text{z-score}(y)] \end{aligned}
Agenda
Survey Sampling
Correlation
Quantile-Quantile Plot
Deciphering Problem Set 2
Agenda
Survey Sampling
Correlation
Quantile-Quantile Plot
Deciphering Problem Set 2
progressive.vote - The proportion of the judge’s votes on women’s issues which were decided in a pro-feminist direction.progressive.vote and two confounders - republican and womanprogressive.vote and two confounders - whether a judge has at least one child and republicanprogressive.vote and explanatory variable - whether a judge has at least one daughter, conditional on the total number of children
progressive.vote?progressive.vote?progressive.vote.progressive.vote across 4 groups: Republican men, Republican women, Democratic men, Democratic women. (Hint: y ~ x1 + x2 in boxplot())progressive.vote between judges who have at least one child and those who don’t.progressive.vote between Republican and Democratic parents.
tapply(..., list(..., ...), mean)progressive.vote between judges who have at least one daughter and those who don’t have any.tapply(..., list(..., ...), mean)Conditional on the number of children, the number of daughters a judge has is random. How can we evaluate the validity of this assumption?
girls across judges with different number of children.girls across judges, divided by other potential confounders in the data.
CSSS/SOC/STAT 321 bostona Science and Statistics for Social Scicence I